package com.happyfamily.springboot.crowdsourcingplatform.service.pan;

import com.happyfamily.springboot.crowdsourcingplatform.base.result.Results;
import com.happyfamily.springboot.crowdsourcingplatform.model.Work;

/**
 * @Author Administrator
 * @create 2020/02/23 01:22
 */
public interface PurchaseService
{

	/**
	 * 拿取作品列表
	 * @param startPosition
	 * @param limit
	 * @return
	 */
	Results<Work> getAllWorksByPage(Integer startPosition, Integer limit);


	/**
	 * 根据作品id那作品信息
	 * @param wid
	 * @return
	 */
	Work getWorkById(Integer wid);


	/**
	 * 将发布的作品更改为已下单
 	 * @param wid
	 * @param account
	 * @return
	 */
	int updateWork(String wid, String account);


	/**
	 * 查询订单id
	 * @param wid
	 * @return
	 */
	Integer getOrdesById(String wid);
}
